<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/html">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="target-densitydpi=device-dpi, width=device-width, initial-scale=1.0, maximum-scale=1">
    <meta name="description" content="Modern UI CSS">
    <meta name="author" content="Sergey Pimenov">
    <meta name="keywords" content="windows 8, modern style, modern ui, style, modern, css, framework">

  	<link href="css/modern.css" rel="stylesheet">
    <link href="css/site.css" rel="stylesheet" type="text/css">
    <link href="js/google-code-prettify/prettify.css" rel="stylesheet" type="text/css">

    <script src="js/jquery-1.8.2.min.js"></script>
    <script src="js/google-analytics.js"></script>
    <script src="js/github.info.js"></script>
    <script src="js/google-code-prettify/prettify.js"></script>
    <script src="js/pagecontrol.js"></script>
    <script src="admin/js/raphael-min.js"></script>
    <script src="admin/js/g.raphael-min.js"></script>
    <script src="admin/js/g.pie-min.js"></script>
	<script type="text/javascript" src="https://www.google.com/jsapi"></script>
	

    <title>Statistics</title>
    <style>
        body {
            background: ;
        }
    </style>
   <style type="text/css">  
            #canvas_container {  
                width: 500px;
                height: 500px;  
                border: 0px solid #aaa;
            }  
    </style>
        
</head>


<body class="modern-ui" onload="prettyPrint()">
<%
	String id = request.getParameter("id");
%>
    <div class="page secondary fixed-header">
        <div class="page-header">
            <div class="page-header-content">
            	<div class="user-login">
                    <div class="name">
                        <span class="first-name"><%=id%></span>
                        <span class="last-name"></span>
                    </div>
                    <div class="avatar">
                        <img src="/Website/icon/manager.png"/>
                    </div>
            	</div>
                <h1>Statistics</h1>
                <a href="/Website/index_manager.jsp?id=<%=id %>" class="back-button big page-back"></a>
            </div>
        </div>

      <div class="page-region">
      	<div class="page-region-content">
				<br>
				<br>
				<br>
				
                <div class="page-control span10" data-role="page-control">
                    <ul>
                        <li class="active"><a href="#page1">Flight Manifest</a></li>
                    </ul>
					
                    <div class="frames">
                        <div class="frame active" id="page1">
                        	<form action = "/Website/ViewManifestURL" method = "get"> 
	                            <table class="hovered" style="padding: 20px; width: 700px;">
	                            	<thead>
										<tr>
											<th class="Left">ID</th>
											<th class="left">Date</th>
											<th class="left">Airline</th>
											<th class="left">Leaving From</th>
											<th class="left">Destination</th>
											<th class="left">Price</th>
											<th class="left">Avaliable Seats</th>
										</tr>
											<tbody>
												<c:forEach items="${flightList}" var="flightInfo">
													<tr>						
														<td>
															<label class="radio" onclick="">
							                     				<input type="radio" name="r1" value = "${flightInfo.flightID}"/>
							                     				<span><c:out value="${flightInfo.flightID}" /></span>
							                 				</label>	
														</td>
														<td><c:out value="${flightInfo.departureTime}" /></td>
														<td><c:out value="${flightInfo.airline}" /></td>
														<td><c:out value="${flightInfo.departureLocation}" /></td>
														<td><c:out value="${flightInfo.arrivalLocation}" /></td>
														<td><c:out value="${flightInfo.price}" /></td>
														<td><c:out value="${flightInfo.seatsLeft}" /></td>		
													</tr>
												</c:forEach>														
											</tbody>						
									</thead>
	                            </table>
	                            <div align=left>
	                            	<input type = "hidden" name = "id" value = <%=id%>>
									<input type="submit" name = "view" value="View" style="margin-left: 600px" />
								</div>	                            
	                    	</form>
                        </div>
                    </div>
                 </div>
             </div>
          </div>
      </div>
</body>
</html>